package com.yanzhu.constant;

/**
 * @Author: 方炎柱
 * @Description:
 * @Date: Created in 15:56 2017/12/25
 * @Modified:
 */
public enum ExceptionEnum {
    // 系统级别异常
    NOT_AUTHTICATION(401, "没有权限！"),

    // 业务级别异常 10000 ~ 20000
    QUERY_ERROR(10001, "查询出错！"),
    INSETR_ERROR(10002, "添加报错！"),
    DELETE_ERROR(10003, "删除报错！"),
    ;

    private int code;

    private String message;

    ExceptionEnum(int code, String message){
        this.code = code;
        this.message = message;
    }

    public int getCode(){
        return code;
    }

    public String getMessage(){
        return message;
    }
}
